package com.example.sangong.utils;

import java.time.LocalDateTime;
import java.time.ZoneOffset;

public class MyLocalDateTimeUtils {


    /**
     * 计算两个时间的毫秒值
     * @param start
     * @param end
     * @return
     */
    public static long minus(LocalDateTime start, LocalDateTime end){
        long startTime = start.toInstant(ZoneOffset.of("+8")).toEpochMilli();
        long endTime = end.toInstant(ZoneOffset.of("+8")).toEpochMilli();
        return endTime - startTime;

    }
}
